package py.com.alfa.escriba.web.services;

import java.util.List;

import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import py.com.alfa.escriba.exception.ServiceException;
import py.com.alfa.escriba.persistence.dto.ComparecientesDTO;
import py.com.alfa.escriba.web.interceptor.InvocationContext;

public interface LegitimacionesService {
  List<ComparecientesDTO> listLegitimaciones(InvocationContext ic) throws ServiceException;
  ComparecientesDTO getLegitimaciones(Long id, InvocationContext ic) throws ServiceException;
  void deleteLegitimaciones(Long id, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  ComparecientesDTO updateLegitimaciones(Long id, ComparecientesDTO dto, InvocationContext ic) throws ServiceException;
  @Transactional(value="transactionManager", rollbackFor={ServiceException.class},propagation=Propagation.REQUIRED)
  ComparecientesDTO createLegitimaciones(ComparecientesDTO dto, InvocationContext ic) throws ServiceException;
}